import { createRouter, createWebHistory, RouteRecordRaw } from "vue-router";
// import Layout from "../layout";

const routes: Array<RouteRecordRaw> = [
  {
    path: "/",
    name: "Home",
    component: () => import ( "../views/Home")
  },
  // {
  //   path: '',
  //   component: Layout,
  //   redirect: '/home',
  //   children: [{
  //     path: 'home',
  //     name: 'home',
  //     component: () => import('../views/Home.vue'),
  //     // meta: {title: '仪表盘', icon: 'el-icon-menu'},
  //   }]
  // },
  {
    path: "/about",
    name: "About",
    component: () => import ( "../views/About")
  }
];

const router = createRouter({
  history: createWebHistory(process.env.BASE_URL),
  routes
});

export default router;
